|
diffpress5 2.2.1
|
This file contains API for Diff Press 5 Click Driver. More...
#include "drv_digital_out.h"#include "drv_digital_in.h"#include "drv_analog_in.h"#include "drv_i2c_master.h"Go to the source code of this file.
Data Structures | |
| struct | diffpress5_t |
| Diff Press 5 Click context object. More... | |
| struct | diffpress5_cfg_t |
| Diff Press 5 Click configuration object. More... | |
Macros | |
| #define | DIFFPRESS5_PRESSURE_PA_MIN 0 |
| Diff Press 5 pressure calculation setting. | |
| #define | DIFFPRESS5_PRESSURE_PA_MAX 10000 |
| #define | DIFFPRESS5_PRESSURE_SENS_PA 0.00045 |
| #define | DIFFPRESS5_ADC_VOUT_MULTIPLIER 1.5 |
| #define | DIFFPRESS5_NUM_CONVERSIONS 200 |
| Diff Press 5 default ADC samples number for averaging. | |
| #define | DIFFPRESS5_ADC_RESOLUTION 0x0FFF |
| Diff Press 5 ADC setting. | |
| #define | DIFFPRESS5_VREF_3V3 3.3 |
| #define | DIFFPRESS5_VREF_5V 5.0 |
| #define | DIFFPRESS5_TIMEOUT_MS 2000 |
| Diff Press 5 timeout setting. | |
| #define | DIFFPRESS5_SET_DEV_ADDR 0x4D |
| Diff Press 5 device address setting. | |
| #define | DIFFPRESS5_MAP_MIKROBUS(cfg, mikrobus) |
| MikroBUS pin mapping. | |
Enumerations | |
| enum | diffpress5_drv_t { DIFFPRESS5_DRV_SEL_ADC , DIFFPRESS5_DRV_SEL_I2C } |
| Diff Press 5 Click driver selector. More... | |
| enum | diffpress5_return_value_t { DIFFPRESS5_OK = 0 , DIFFPRESS5_ERROR = -1 } |
| Diff Press 5 Click return value data. More... | |
Functions | |
| void | diffpress5_cfg_setup (diffpress5_cfg_t *cfg) |
| Diff Press 5 configuration object setup function. | |
| void | diffpress5_drv_interface_sel (diffpress5_cfg_t *cfg, diffpress5_drv_t drv_sel) |
| Diff Press 5 driver interface setup function. | |
| err_t | diffpress5_init (diffpress5_t *ctx, diffpress5_cfg_t *cfg) |
| Diff Press 5 initialization function. | |
| err_t | diffpress5_read_adc_raw (diffpress5_t *ctx, uint16_t *raw_adc) |
| Diff Press 5 read raw ADC value function. | |
| err_t | diffpress5_read_adc_voltage (diffpress5_t *ctx, float *voltage) |
| Diff Press 5 read voltage level function. | |
| err_t | diffpress5_set_vref (diffpress5_t *ctx, float vref) |
| Diff Press 5 set vref function. | |
| err_t | diffpress5_read_vout (diffpress5_t *ctx, float *vout) |
| Diff Press 5 read vout function. | |
| err_t | diffpress5_read_vout_avg (diffpress5_t *ctx, uint16_t num_conv, float *vout_avg) |
| Diff Press 5 read vout avg function. | |
| err_t | diffpress5_calib_offset (diffpress5_t *ctx) |
| Diff Press 5 calib offset function. | |
| err_t | diffpress5_read_pressure (diffpress5_t *ctx, uint16_t *pressure) |
| Diff Press 5 read pressure function. | |
This file contains API for Diff Press 5 Click Driver.
| enum diffpress5_drv_t |